package stream第二遍.demo04;

import java.util.stream.Stream;

/**
 * @author wql
 * @version 1.0
 * @date 2022/11/6 12:10
 */

public class Test {
    public static void main(String[] args) {
        String [] arr={"你","是"};
        String [] arr1={"我","的","花","花","朵"};
        Stream<String> arr2 = Stream.of(arr);
        Stream<String> arr3 = Stream.of(arr1);
        //合并
       // Stream.concat(arr2,arr3).forEach(System.out::println);

        //去重
      //  Stream.concat(arr2,arr3).distinct().forEach(System.out::println);

        //限制
      //  Stream.concat(arr2,arr3).limit(4).forEach(System.out::println);

        //跳过
        Stream.concat(arr2,arr3).skip(3).forEach(System.out::println);
    }
}
